/**
 * <strong>Title : DefectService.java<br>
 * </strong> <strong>Package : cn.b.sky.mes.qm.service<br>
 * </strong> <strong>Description : </strong>@类注释说明写在此处@<br>
 * <strong>Create on : 2015年12月15日 上午9:50:06<br>
 * </strong>
 * <p>
 * @author dapeng.li<br>
 * @version <strong>v1.0.0</strong><br>
 * <br>
 *          <strong>修改历史:</strong><br>
 *          修改人 | 修改日期 | 修改描述<br>
 *          -------------------------------------------<br>
 * <br>
 * <br>
 */
package cn.b.sky.mes.qm.service;

import java.util.List;

import cn.b.sky.common.model.BatchJobReport;
import cn.b.sky.mes.qm.model.Defect;
import cn.b.sky.mes.qm.model.condition.DefectCondition;

/**
 * <strong>Title : DefectService.java<br></strong>
 * <strong>Package : cn.b.sky.mes.qm.service<br></strong>
 * <strong>Description : </strong>缺陷业务接口<br> 
 * <strong>Create on : 2015年12月15日 上午9:50:06<br></strong>
 * <p>
 * @author dapeng.li<br>
 * @version <strong>v1.0.0</strong><br>
 * <br>
 * <strong>修改历史:</strong><br>
 * 修改人 | 修改日期 | 修改描述<br>
 * -------------------------------------------<br>
 * <br>
 * <br>
 */
public interface DefectService {

  List<Defect> selectDefectListByCondition(DefectCondition condition);

  int selectDefectCountByCondition(DefectCondition condition);

  Defect getDefect(String defectCode, String siteCode);

  boolean insertDefect(Defect defect);

  boolean updateDefect(Defect defect);

  BatchJobReport deleteDefect(String defectCode, String siteCode);

  /**
   * <strong>Title : selectDefectListLookUpByCondition<br></strong>
   * <strong>Description : </strong>查找带回<br> 
   * <strong>Create on : 2015-12-17 下午3:38:26<br></strong>
   * <p>
   * @param condition
   * @return
   * List<Defect>
   * @throws 
   * @author lidapeng<br>
   * @version <strong>v1.0.0</strong><br>
   * <br>
   * <strong>修改历史:</strong><br>
   * 修改人 | 修改日期 | 修改描述<br>
   * -------------------------------------------<br>
   * <br>
   * <br>
   */
  List<Defect> selectDefectListSuggestByCondition(DefectCondition condition);

  /**
   * 
   * <strong>Title : selectDefectOnly<br></strong>
   * <strong>Description : </strong>仅查询单条缺陷<br> 
   * <strong>Create on : 2015-12-30 下午02:55:16<br></strong>
   * <p>
   * @param defectCode
   * @param siteCode
   * @return
   * Defect
   * @throws 
   * @author zhaoxin01<br>
   * @version <strong>v1.0.0</strong><br>
   * <br>
   * <strong>修改历史:</strong><br>
   * 修改人 | 修改日期 | 修改描述<br>
   * -------------------------------------------<br>
   * <br>
   * <br>
   */
  Defect selectDefectOnly(String defectCode, String siteCode);
}
